import request from './index'

interface ResponseType<T> {
	code: number
	message: string
	data: T
}
type demo = object[]

export function getDetail(params: any) {
	return request<ResponseType<demo>>({
		url: 'goods/detail',
		method: 'get',
		params
	})
}

export function getList(data: any) {
	return request<ResponseType<demo>>({
		url: 'goods/list',
		method: 'post',
		data
	})
}
